FROM nvidia/cuda:11.8.0-base-ubuntu22.04

ENV DEBIAN_FRONTEND=noninteractive

RUN apt-get update && \
    apt-get install -y --no-install-recommends \
    wget \
    curl \
    ca-certificates \
    python3.10 \
    python3.10-venv \
    python3-pip \
    git && \
    rm -rf /var/lib/apt/lists/*

RUN python3.10 -m pip install --no-cache-dir uv -i https://pypi.tuna.tsinghua.edu.cn/simple

RUN python3.10 -m uv pip install --no-cache \
    torch==2.7.1 --index-url https://download.pytorch.org/whl/cu118 \
    accelerate \
    transformers \
    --extra-index-url https://pypi.tuna.tsinghua.edu.cn/simple

COPY server_eval_runner.py /app/run.py

# 7. 设置工作目录
WORKDIR /app

# 8. 默认命令
CMD ["/bin/bash"]